home *** CD-ROM | disk | FTP | other *** search
/ SGI Freeware 2002 November / SGI Freeware 2002 November - Disc 2.iso / dist / fw_glib.idb / usr / freeware / info / glib.info.z / glib.info
Text File  |  2001-10-09  |  16KB  |  512 lines

  1. This is glib.info, produced by Makeinfo version 3.12f from glib.texi.
  2.  
  3.    This file documents GLIB, A library of useful routines for C
  4. programming
  5.  
  6.    Copyright (C) 1998 Gregory A McLean
  7.  
  8.    Permission is granted to make and distributed verbatim copies of this
  9. manual, provided the copyright notice and this permission notice are
  10. preserved on all copies.
  11.  
  12.    Permission is granted to copy and distribute modified versions of
  13. this manual under the conditions for verbatim copying, provided that the
  14. entire resulting derived work is distributed under the terms of a
  15. permission notice identical to this one.
  16.  
  17.    Permission is granted to copy and distribute translations of this
  18. manual into another language, under the above conditions for modified
  19. versions, except that this permission notice may be stated in a
  20. translation approved by Gregory McLean.
  21.  
  22. INFO-DIR-SECTION Library of useful routines for 'C' programing
  23. START-INFO-DIR-ENTRY
  24. * GLIB: (glib).        useful routines for 'C' programming
  25. END-INFO-DIR-ENTRY
  26.  
  27. 
  28. File: glib.info,  Node: Top,  Next: Copying,  Prev: (dir),  Up: (dir)
  29.  
  30. useful routines for 'C' programming
  31. ***********************************
  32.  
  33.    This is edition 1.0 of the GLIB documentation, 3 Feburary 1998.
  34.  
  35. * Menu:
  36.  
  37. * Copying::                     Your rights.
  38. * Overview::                    What is GLIB?
  39. * Doubly linked lists::         Doubly linked lists
  40. * Signly linked lists::         Singly linked lists
  41. * List allocators::             List Allocators
  42. * Hash tables::                 Hash tables
  43. * Caches::                      Cache handling
  44. * Trees::                       Tree handling
  45. * Memory::                      Memory handling
  46. * Timers::                      Timer functions
  47. * Output::                      Output handling
  48. * Utilities::                   Utilitiy functions
  49. * Errors::                      Error handling
  50. * String Chunks::               String Chunks
  51. * Strings::                     String handling
  52. * Resizable arrays::            Resizeable arrays
  53. * GScanner::                    Flexible lexical scanner
  54. * Miscellany::                  Other stuff
  55. * Function Index::              Index of functions
  56. * Concept Index::               Index of concepts
  57.  
  58. 
  59. File: glib.info,  Node: Copying,  Next: Overview,  Prev: Top,  Up: Top
  60.  
  61. Copying
  62. *******
  63.  
  64. 
  65. File: glib.info,  Node: Overview,  Next: Doubly linked lists,  Prev: Copying,  Up: Top
  66.  
  67. What is GLIB
  68. ************
  69.  
  70. 
  71. File: glib.info,  Node: Doubly linked lists,  Next: Signly linked lists,  Prev: Overview,  Up: Top
  72.  
  73. Doubly linked lists
  74. *******************
  75.  
  76. Functions
  77. ---------
  78.  
  79.  - Function: GList* g_list_alloc (void)
  80.  
  81.  - Function: void g_list_free (GList *LIST)
  82.  
  83.  - Function: void g_list_free_1 (GList *LIST)
  84.  
  85.  - Function: GList* g_list_append (GList *LIST, gpointer DATA)
  86.  
  87.  - Function: GList* g_list_prepend (GList *LIST, gpointer DATA)
  88.  
  89.  - Function: GList* g_list_insert (GList *LIST, gpointer DATA, gint
  90.           POSITION)
  91.  
  92.  - Function: GList* g_list_insert_sorted (GList *LIST, gpointer DATA,
  93.           GCompareFunc FUNC)
  94.  
  95.  - Function: GList* g_list_concat (GList *LIST1, GList *LIST2)
  96.  
  97.  - Function: GList* g_list_remove (GList *LIST, gpointer DATA)
  98.  
  99.  - Function: GList* g_list_remove_link (GList *LIST, GList *LINK)
  100.  
  101.  - Function: GList* g_list_reverse (GList *LIST)
  102.  
  103.  - Function: GList* g_list_nth (GList *LIST, gint N)
  104.  
  105.  - Function: GList* g_list_find (GList *LIST, gpointer DATA)
  106.  
  107.  - Function: GList* g_list_last (GList *LIST)
  108.  
  109.  - Function: GList* g_list_first (GList *LIST)
  110.  
  111.  - Function: gint g_list_length (GList *LIST)
  112.  
  113.  - Function: void g_list_foreach (GList *LIST, GFunc FUNC, gpointer
  114.           USER_DATA)
  115.  
  116. 
  117. File: glib.info,  Node: Signly linked lists,  Next: List allocators,  Prev: Doubly linked lists,  Up: Top
  118.  
  119. Signly linked lists
  120. *******************
  121.  
  122. Functions
  123. ---------
  124.  
  125.  - Function: GSList* g_slist_alloc (void)
  126.  
  127.  - Function: void g_slist_free (GSList *LIST)
  128.  
  129.  - Function: void g_slist_free_1 (GSList *LIST)
  130.  
  131.  - Function: GSList* g_slist_append (GSList *LIST, gpointer DATA)
  132.  
  133.  - Function: GSList* g_slist_prepend (GSList *LIST, gpointer DATA)
  134.  
  135.  - Function: GSList* g_slist_insert (GSList *LIST, gpointer DATA, gint
  136.           POSITION)
  137.  
  138.  - Function: GSList* g_slist_insert_sorted (GSList *LIST, gpointer
  139.           DATA, GCompareFunc FUNC)
  140.  
  141.  - Function: GSList* g_slist_concat (GSList *LIST1, GSList *LIST2)
  142.  
  143.  - Function: GSList* g_slist_remove (GSList *LIST, gpointer DATA)
  144.  
  145.  - Function: GSList* g_slist_remove_link (GSList *LIST, GSList *LINK)
  146.  
  147.  - Function: GSList* g_slist_reverse (GSList *LIST)
  148.  
  149.  - Function: GSList* g_slist_nth (GSList *LIST, gint N)
  150.  
  151.  - Function: GSList* g_slist_find (GSList *LIST, gpointer DATA)
  152.  
  153.  - Function: GSList* g_slist_last (GSList *LIST)
  154.  
  155.  - Function: gint g_slist_length (GSList *LIST)
  156.  
  157.  - Function: void g_slist_foreach (GSList *LIST, GFunc FUNC, gpointer
  158.           USER_DATA)
  159.  
  160. 
  161. File: glib.info,  Node: List allocators,  Next: Hash tables,  Prev: Signly linked lists,  Up: Top
  162.  
  163. List allocators
  164. ***************
  165.  
  166. Functions
  167. ---------
  168.  
  169.  - Function: GListAllocator* g_list_allocator_new (void)
  170.  
  171.  - Function: void g_list_allocator_free (GListAllocator *ALLOCATOR)
  172.  
  173.  - Function: GListAllocator* g_slist_set_allocator (GListAllocator
  174.           *ALLOCATOR)
  175.  
  176.  - Function: GListAllocator* g_list_set_allocator (GListAllocator
  177.           *ALLOCATOR)
  178.  
  179. 
  180. File: glib.info,  Node: Hash tables,  Next: Caches,  Prev: List allocators,  Up: Top
  181.  
  182. Hash tables
  183. ***********
  184.  
  185. Functions
  186. ---------
  187.  
  188.  - Function: GHashTable* g_hash_table_new (GHashFunc HASH_FUNC,
  189.           GCompareFunc KEY_COMPARE_FUNC)
  190.  
  191.  - Function: void g_hash_table_destroy (GHashTable *HASH_TABLE)
  192.  
  193.  - Function: void g_hash_table_insert (GHashTable *HASH_TABLE, gpointer
  194.           KEY, gpointer VALUE)
  195.  
  196.  - Function: void g_hash_table_remove (GHashTable *HASH_TABLE, gpointer
  197.           KEY)
  198.  
  199.  - Function: gpointer g_hash_table_lookup (GHashTable *HASH_TABLE,
  200.           gpointer KEY)
  201.  
  202.  - Function: void g_hash_table_freeze (GHashTable *HASH_TABLE)
  203.  
  204.  - Function: void g_hash_table_thaw (GHashTable *HASH_TABLE)
  205.  
  206.  - Function: void g_hash_table_foreach (GHashTable *HASH_TABLE, GHFunc
  207.           FUNC, gpointer USER_DATA)
  208.  
  209. 
  210. File: glib.info,  Node: Caches,  Next: Trees,  Prev: Hash tables,  Up: Top
  211.  
  212. Cache handling
  213. **************
  214.  
  215. Functions
  216. ---------
  217.  
  218.  - Function: GCache* g_cache_new (GCacheNewFunc VALUE_NEW_FUNC,
  219.           GCacheDestroyFunc VALUE_DESTROY_FUNC, GCacheDupFunc
  220.           KEY_DUP_FUNC, GCacheDestroyFunc KEY_DESTROY_FUNC, GHashFunc
  221.           HASH_KEY_FUNC, GHashFunc HASH_VALUE_FUNC, GCompareFunc
  222.           KEY_COMPARE_FUNC)
  223.  
  224.  - Function: void g_cache_destroy (GCache *CACHE)
  225.  
  226.  - Function: gpointer g_cache_insert (GCache *CACHE, gpointer KEY)
  227.  
  228.  - Function: void g_cache_remove (GCache *CACHE, gpointer KEY)
  229.  
  230.  - Function: void g_cache_key_foreach (GCache *CACHE, GHFunc FUNC,
  231.           gpointer USER_DATA)
  232.  
  233.  - Function: void g_cache_value_foreach (GCache *CACHE, GHFunc FUNC,
  234.           gpointer USER_DATA)
  235.  
  236. 
  237. File: glib.info,  Node: Trees,  Next: Memory,  Prev: Caches,  Up: Top
  238.  
  239. Tree handling
  240. *************
  241.  
  242. Functions
  243. ---------
  244.  
  245.  - Function: GTree* g_tree_new (GCompareFunc KEY_COMPARE_FUNC)
  246.  
  247.  - Function: void g_tree_destroy (GTree *TREE)
  248.  
  249.  - Function: void g_tree_remove (GTree *TREE, gpointer KEY, gpointer
  250.           VALUE)
  251.  
  252.  - Function: gpointer g_tree_lookup (GTree *TREE, gpointer KEY)
  253.  
  254.  - Function: void g_tree_traverse (GTree *TREE, GTraverseFunc
  255.           TRAVERSE_FUNC, GTraverseType TRAVERSE_TYPE, gpointer DATA
  256.  
  257.  - Function: gpointer g_tree_search (GTree *TREE, GSearchFunc
  258.           SEARCH_FUNC, gpointer DATA)
  259.  
  260.  - Function: gint g_tree_height (GTree *TREE)
  261.  
  262.  - Function: gint g_tree_nnodes (GTree *TREE)
  263.  
  264. 
  265. File: glib.info,  Node: Memory,  Next: Timers,  Prev: Trees,  Up: Top
  266.  
  267. Memory handling
  268. ***************
  269.  
  270. Functions
  271. ---------
  272.  
  273.  - Function: gpointer g_malloc (gulong SIZE)
  274.  
  275.  - Function: gpointer g_malloc0 (gulong SIZE)
  276.  
  277.  - Function: gpointer g_realloc (gpointer MEM, gulong SIZE)
  278.  
  279.  - Function: void g_mem_profile (void)
  280.  
  281.  - Function: void g_mem_check (gpointer MEM)
  282.  
  283.  - Function: GMemChunk* g_mem_chunk_new (gchar *NAME, gint ATOM_SIZE,
  284.           gulong AREA_SIZE, gint TYPE)
  285.  
  286.  - Function: void g_mem_chunk_destroy (GMemChunk *MEM_CHUNK)
  287.  
  288.  - Function: gpointer g_mem_chunk_alloc (GMemChunk *MEM_CHUNK)
  289.  
  290.  - Function: void g_mem_chunk_free (GMemChunk *MEM_CHUNK, gpointer MEM)
  291.  
  292.  - Function: void g_mem_chunk_clean (GMemChunk *MEM_CHUNK)
  293.  
  294.  - Function: void g_mem_chunk_reset (GMemChunk *MEM_CHUNK)
  295.  
  296.  - Function: void g_mem_chunk_print (GMemChunk *MEM_CHUNK)
  297.  
  298.  - Function: void g_mem_chunk_info (void)
  299.  
  300.  - Function: void g_blow_chunks (void)
  301.      Not what you might be thinking, `g_blow_chunks()' simply
  302.      compresses all the chunks. This operation consists of freeing
  303.      every memory area that should be freed (but which we haven't
  304.      gotten around to doing yet).
  305.  
  306. 
  307. File: glib.info,  Node: Timers,  Next: Output,  Prev: Memory,  Up: Top
  308.  
  309. Timer functions
  310. ***************
  311.  
  312. Functions
  313. ---------
  314.  
  315.  - Function: GTimer* g_timer_new (void)
  316.  
  317.  - Function: void g_timer_destroy (GTimer *TIMER)
  318.  
  319.  - Function: void g_timer_start (GTimer *TIMER)
  320.  
  321.  - Function: void g_timer_stop (GTimer *TIMER)
  322.  
  323.  - Function: void g_timer_reset (GTimer *TIMER)
  324.  
  325.  - Function: gdouble g_timer_elapsed (GTimer *TIMER, gulong
  326.           *MICROSECONDS)
  327.  
  328. 
  329. File: glib.info,  Node: Output,  Next: Utilities,  Prev: Timers,  Up: Top
  330.  
  331. Output functions
  332. ****************
  333.  
  334. Functions
  335. ---------
  336.  
  337.  - Function: void g_error (gchar *FORMAT, ...)
  338.  
  339.  - Function: void g_warning (gchar *FORMAT, ...)
  340.  
  341.  - Function: void g_message (gchar *FORMAT, ...)
  342.  
  343.  - Function: void g_print (gchar *FORMAT, ...)
  344.  
  345. 
  346. File: glib.info,  Node: Utilities,  Next: Errors,  Prev: Output,  Up: Top
  347.  
  348. Utility functions
  349. *****************
  350.  
  351. 
  352. File: glib.info,  Node: Errors,  Next: String Chunks,  Prev: Utilities,  Up: Top
  353.  
  354. Error handling
  355. **************
  356.  
  357. 
  358. File: glib.info,  Node: String Chunks,  Next: Strings,  Prev: Errors,  Up: Top
  359.  
  360. String chunks
  361. *************
  362.  
  363. 
  364. File: glib.info,  Node: Strings,  Next: Resizable arrays,  Prev: String Chunks,  Up: Top
  365.  
  366. String handling
  367. ***************
  368.  
  369. 
  370. File: glib.info,  Node: Resizable arrays,  Next: GScanner,  Prev: Strings,  Up: Top
  371.  
  372. Resizable arrays
  373. ****************
  374.  
  375. 
  376. File: glib.info,  Node: GScanner,  Next: Miscellany,  Prev: Resizable arrays,  Up: Top
  377.  
  378. Flexible lexical scanner
  379. ************************
  380.  
  381. 
  382. File: glib.info,  Node: Miscellany,  Next: Function Index,  Prev: GScanner,  Up: Top
  383.  
  384. Other stuff
  385. ***********
  386.  
  387. 
  388. File: glib.info,  Node: Function Index,  Next: Concept Index,  Prev: Miscellany,  Up: Top
  389.  
  390. Function Index
  391. **************
  392.  
  393. * Menu:
  394.  
  395. * g_blow_chunks:                         Memory.
  396. * g_cache_destroy:                       Caches.
  397. * g_cache_insert:                        Caches.
  398. * g_cache_key_foreach:                   Caches.
  399. * g_cache_new:                           Caches.
  400. * g_cache_remove:                        Caches.
  401. * g_cache_value_foreach:                 Caches.
  402. * g_error:                               Output.
  403. * g_hash_table_destroy:                  Hash tables.
  404. * g_hash_table_foreach:                  Hash tables.
  405. * g_hash_table_freeze:                   Hash tables.
  406. * g_hash_table_insert:                   Hash tables.
  407. * g_hash_table_lookup:                   Hash tables.
  408. * g_hash_table_new:                      Hash tables.
  409. * g_hash_table_remove:                   Hash tables.
  410. * g_hash_table_thaw:                     Hash tables.
  411. * g_list_alloc:                          Doubly linked lists.
  412. * g_list_allocator_free:                 List allocators.
  413. * g_list_allocator_new:                  List allocators.
  414. * g_list_append:                         Doubly linked lists.
  415. * g_list_concat:                         Doubly linked lists.
  416. * g_list_find:                           Doubly linked lists.
  417. * g_list_first:                          Doubly linked lists.
  418. * g_list_foreach:                        Doubly linked lists.
  419. * g_list_free:                           Doubly linked lists.
  420. * g_list_free_1:                         Doubly linked lists.
  421. * g_list_insert:                         Doubly linked lists.
  422. * g_list_insert_sorted:                  Doubly linked lists.
  423. * g_list_last:                           Doubly linked lists.
  424. * g_list_length:                         Doubly linked lists.
  425. * g_list_nth:                            Doubly linked lists.
  426. * g_list_prepend:                        Doubly linked lists.
  427. * g_list_remove:                         Doubly linked lists.
  428. * g_list_remove_link:                    Doubly linked lists.
  429. * g_list_reverse:                        Doubly linked lists.
  430. * g_list_set_allocator:                  List allocators.
  431. * g_malloc:                              Memory.
  432. * g_malloc0:                             Memory.
  433. * g_mem_check:                           Memory.
  434. * g_mem_chunk_alloc:                     Memory.
  435. * g_mem_chunk_clean:                     Memory.
  436. * g_mem_chunk_destroy:                   Memory.
  437. * g_mem_chunk_free:                      Memory.
  438. * g_mem_chunk_info:                      Memory.
  439. * g_mem_chunk_new:                       Memory.
  440. * g_mem_chunk_print:                     Memory.
  441. * g_mem_chunk_reset:                     Memory.
  442. * g_mem_profile:                         Memory.
  443. * g_message:                             Output.
  444. * g_print:                               Output.
  445. * g_realloc:                             Memory.
  446. * g_slist_alloc:                         Signly linked lists.
  447. * g_slist_append:                        Signly linked lists.
  448. * g_slist_concat:                        Signly linked lists.
  449. * g_slist_find:                          Signly linked lists.
  450. * g_slist_foreach:                       Signly linked lists.
  451. * g_slist_free:                          Signly linked lists.
  452. * g_slist_free_1:                        Signly linked lists.
  453. * g_slist_insert:                        Signly linked lists.
  454. * g_slist_insert_sorted:                 Signly linked lists.
  455. * g_slist_last:                          Signly linked lists.
  456. * g_slist_length:                        Signly linked lists.
  457. * g_slist_nth:                           Signly linked lists.
  458. * g_slist_prepend:                       Signly linked lists.
  459. * g_slist_remove:                        Signly linked lists.
  460. * g_slist_remove_link:                   Signly linked lists.
  461. * g_slist_reverse:                       Signly linked lists.
  462. * g_slist_set_allocator:                 List allocators.
  463. * g_timer_destroy:                       Timers.
  464. * g_timer_elapsed:                       Timers.
  465. * g_timer_new:                           Timers.
  466. * g_timer_reset:                         Timers.
  467. * g_timer_start:                         Timers.
  468. * g_timer_stop:                          Timers.
  469. * g_tree_destroy:                        Trees.
  470. * g_tree_height:                         Trees.
  471. * g_tree_lookup:                         Trees.
  472. * g_tree_new:                            Trees.
  473. * g_tree_nnodes:                         Trees.
  474. * g_tree_remove:                         Trees.
  475. * g_tree_search:                         Trees.
  476. * g_tree_traverse:                       Trees.
  477. * g_warning:                             Output.
  478.  
  479. 
  480. File: glib.info,  Node: Concept Index,  Prev: Function Index,  Up: Top
  481.  
  482. Concept Index
  483. *************
  484.  
  485. * Menu:
  486.  
  487. 
  488. Tag Table:
  489. Node: Top1013
  490. Node: Copying2205
  491. Node: Overview2296
  492. Node: Doubly linked lists2413
  493. Node: Signly linked lists3621
  494. Node: List allocators4833
  495. Node: Hash tables5294
  496. Node: Caches6117
  497. Node: Trees6918
  498. Node: Memory7631
  499. Node: Timers8799
  500. Node: Output9251
  501. Node: Utilities9580
  502. Node: Errors9694
  503. Node: String Chunks9809
  504. Node: Strings9920
  505. Node: Resizable arrays10045
  506. Node: GScanner10167
  507. Node: Miscellany10308
  508. Node: Function Index10421
  509. Node: Concept Index15119
  510. 
  511. End Tag Table
  512.